﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace SqlScriptRunner
{
    public partial class frmSqlConnection : Form
    {
        public frmSqlConnection()
        {
            InitializeComponent();
        }

        private void frmSqlConnection_Load(object sender, EventArgs e)
        {
            // Add the keywords to the list
            se_code_view.Settings.Keywords.Add("xml");
            se_code_view.Settings.Keywords.Add("schema");
            se_code_view.Settings.Keywords.Add("simpleType");
            se_code_view.Settings.Keywords.Add("restriction");
            se_code_view.Settings.Keywords.Add("complexType");
            se_code_view.Settings.Keywords.Add("element");
            se_code_view.Settings.Keywords.Add("encoding");
            se_code_view.Settings.Keywords.Add("version");
            se_code_view.Settings.Keywords.Add("xmlns");
            se_code_view.Settings.Keywords.Add("xs");
            se_code_view.Settings.Keywords.Add("xmlns");
            se_code_view.Settings.Keywords.Add("xsd");
            se_code_view.Settings.Keywords.Add("name");
            se_code_view.Settings.Keywords.Add("base");
            se_code_view.Settings.Keywords.Add("type");
            se_code_view.Settings.Keywords.Add("value");

            // Set the comment identifier
            se_code_view.Settings.Comment = "<!--";

            // Enable strings and integers highlighting
            se_code_view.Settings.EnableStrings = true;
            se_code_view.Settings.EnableIntegers = true;

            // Set the colors that will be used
            se_code_view.Settings.KeywordColor = Color.Green;
            se_code_view.Settings.CommentColor = Color.Gray;
            se_code_view.Settings.StringColor = Color.Blue;
            se_code_view.Settings.IntegerColor = Color.Red;

            // Let's make the settings we just set valid by compiling
            // the keywords to a regular expression
            se_code_view.CompileKeywords();

        }
    }
}
